<table width="100%" cellspacing="0">
<tbody>
<tr>
<?php if($this->auth) {?>
<td valign="top" bgcolor="#f0f0f0" style="width:170px"><table width = "100%" cellpadding="0" cellspacing="0" bgcolor="#f0f0f0">
  <tr>
    <td><table border="0" cellpadding="3" cellspacing="0" width="100%" style="border-bottom:1px solid blue">
      <tbody>
        <tr>
          <td bgcolor="#dddddd"><span style="float: left;"><b>Project </b></span></td>
        </tr>
      </tbody>
    </table></td>
  </tr>
  <tr>
    <td><table border="0" cellpadding="3" cellspacing="0" width="100%">
      <tbody>
        <tr>
          <td valign="top"><a href="<?=$this->baseUrl()?>/project">Projects</a></td>
        </tr>
      </tbody>
    </table></td>
  </tr>
</table>
  <table width = "100%" cellpadding="0" cellspacing="0" bgcolor="#f0f0f0">
    <tr>
      <td><table border="0" cellpadding="3" cellspacing="0" width="100%" style="border-bottom:1px solid blue">
          <tbody>
            <tr>
              <td bgcolor="#dddddd"><span style="float: left;"><b>User, Groups &amp; Roles </b></span></td>
            </tr>
          </tbody>
      </table></td>
    </tr>
    <tr>
      <td><table border="0" cellpadding="3" cellspacing="0" width="100%">
          <tbody>
            <tr>
              <td valign="top"><a href="<?=$this->baseUrl()?>/user/browse">User Browser </a></td>
            </tr>
            <tr>
              <td valign="top"><a href="<?=$this->baseUrl()?>/groups/browse">Group Browser</a></td>
            </tr>
            <tr>
              <td valign="top"><a href="<?=$this->baseUrl()?>/roles/browse">Project Role Browser </a></td>
            </tr>
          </tbody>
      </table></td>
    </tr>
  </table>
  <table width = "100%" cellpadding="0" cellspacing="0" bgcolor="#f0f0f0">
    <tr>
      <td><table border="0" cellpadding="3" cellspacing="0" width="100%" style="border-bottom:1px solid blue">
          <tbody>
            <tr>
              <td bgcolor="#dddddd"><span style="float: left;"><b>Issue Settings </b></span></td>
            </tr>
          </tbody>
      </table></td>
    </tr>
    <tr>
      <td><table border="0" cellpadding="3" cellspacing="0" width="100%">
          <tbody>
            <tr>
              <td valign="top"><a href="<?=$this->baseUrl()?>/type/manage">Issue types</a></td>
            </tr>
            <tr>
              <td valign="top"><a href="<?=$this->baseUrl()?>/priority/manage">Priorities</a></td>
            </tr>
            <tr>
              <td valign="top"><a href="<?=$this->baseUrl()?>/resolution/manage">Resolutions</a></td>
            </tr>
            <tr>
              <td><a href="<?=$this->baseUrl()?>/status/manage">Statuses</a></td>
            </tr>
          </tbody>
      </table></td>
    </tr>
  </table></td>
<?php }?>
<td valign="top">
<br>
<table width = "98%" align = "center" bgcolor="#bbbbbb" cellspacing="0" style="border:1px solid #bbbbbb">
  <tr bgcolor="#f0f0f0">
	<td height="34" style="border-bottom:0px"><h3 style="margin:3px 0 0 5px;height:20px">Group Browser </h3>
	  </td>
  </tr>
  <tr>
	<td bgcolor="#ffffff"><p> The Group Browser allows you to browse all the groups in the system. You can also add and remove groups from here. </p>
	  <p>Only System Administrators are allowed to delete or edit members of groups with the 'System Administrators' permission</p></td>
  </tr>
</table>
<br>
	<table width="100%">
		<tr>
			<td valign="top"><table width="98%" border="0" align="center" cellpadding="3" cellspacing="1" bgcolor="#bbbbbb" id="issuetable">
              <tbody>
                <tr bgcolor="#f0f0f0">
                  <td class="colHeaderLink" onMouseOver="this.className='colHeaderOver'" onMouseOut="this.className='colHeaderLink'" width="1%" nowrap><b>Group Name </b></td>
                  <td class="colHeaderLink" onMouseOver="this.className='colHeaderOver'" onMouseOut="this.className='colHeaderLink'" width="1%" nowrap><b>Users</b></td>
                  <td class="colHeaderLink" onMouseOver="this.className='colHeaderOver'" onMouseOut="this.className='colHeaderLink'" width="1%" nowrap><b>Permission Scheme </b></td>
                  <td width="3%" nowrap class="colHeaderLink"><strong>Operations</strong></td>
                </tr>
                <?php 
				$i = 1;
				foreach ($this->groups as $group) { ?>
				<tr <?php if($i % 2) { echo "class='rowNormal'"; } else { echo "class='rowAlternate'";}?>>
				  <td valign="top"><a href="<?=$this->baseUrl()?>/group/view/id/<?=$group['id']?>">
					<?=$group['groupname']?>
				  </a></td>
				  <td valign="top">
					<?=$group['users']?>
				  </td>
				  <td valign="top">&nbsp;</td>
				  <td valign="top"><a href="<?=$this->baseUrl()?>/groups/delete/id/<?=$group['id']?>">Delete</a> | <a href="">Edit Members</a> </td>
				</tr>
				<?php 
					$i++;
				}?>
              </tbody>
            </table></td>
			<td width="250">
				<form action="" method="post" id="addGroup" name="addGroup">
					<table width="100%" bgcolor="#bbbbbb" cellpadding="3" cellspacing="1">
						<tr bgcolor="#f0f0f0">
							<td><strong style="color:blue">Add Group</strong></td>
						</tr>
						<tr bgcolor="#fffff0">
							<td><div>Name:</div></td>
						</tr>
						<tr>
						  <td bgcolor="#FFFFFF"><input type="text" name="groupname" id="groupname" /></td>
						</tr>
						<tr>
						  <td align="center" bgcolor="#F0F0F0"><input type="submit" id="add_group" value="Add Group" /></td>
						</tr>
					</table>
				</form>
			</td>
		</tr>
	</table>
</td>
</tr>
</tbody>
</table>